const Comment = require('../../model/comment')
module.exports = async(req, res) => {
    // res.send(req.body)
    let { aid, uid, content } = req.body;
    await Comment.create({
        aid,
        uid,
        time: new Date(),
        content
    });
    res.redirect('/home/article?id=' + aid)
}